﻿using System;
using System.Diagnostics.Contracts;

namespace OpenWaves.Web.Controls
{
    public class MarkerDataBoundEventArgs<T> : EventArgs
    {
        private readonly T dataItem;
        private readonly GeoMarker marker;

        public MarkerDataBoundEventArgs(T dataItem, GeoMarker marker)
        {
            Contract.Requires<ArgumentNullException>(dataItem != null);
            Contract.Requires<ArgumentNullException>(marker != null);

            this.dataItem = dataItem;
            this.marker = marker;
        }

        public T DataItem
        {
            get { return dataItem; }
        }

        public GeoMarker Marker
        {
            get { return marker; }
        }
    }
}